package com.gumball.testdrive;

import java.rmi.Naming;

import com.gumball.context.GumballMachine;

public class GumballMachineTestDrive {

	public static void main(String[] args) {

		int count = 100;
		GumballMachine gumballMachine = null;
		try {
			gumballMachine = new GumballMachine("com.gumball.context", count);
			
			/*Naming.rebind("gumballmachine",
					gumballMachine);*/
			
			Naming.rebind("//" + "localhost" + "/gumballmachine",
					gumballMachine);
			
			/*Naming.rebind("//" + "com.gumball.context" + "/gumballmachine",
					gumballMachine);*/
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
